package com.biostime.rpc.terminal;

import com.mama100.common.finagle.FinagleClientRegister;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class DemoRpcFactory
{
	protected Logger logger = LoggerFactory.getLogger(this.getClass());
	
//	private DemoService.ServiceIface demoService;
//	private HelloService.ServiceIface helloService;
//
	private FinagleClientRegister register;

//
//
//	public synchronized DemoService.ServiceIface getDemoService()
//	{
//		if (demoService == null)
//			try
//			{
//				demoService = (DemoService.ServiceIface) register.getClientService("demoService", DemoService.class.getName());
//			}
//			catch (Exception e)
//			{
//				logger.error("register demoService error", e);
//			}
//
//		return demoService;
//	}
//
//	public synchronized HelloService.ServiceIface getHelloService()
//	{
//		if (helloService == null)
//			try
//			{
//				helloService = (HelloService.ServiceIface) register.getClientService("helloService", HelloService.class.getName());
//			}
//			catch (Exception e)
//			{
//				logger.error("register helloService error", e);
//			}
//
//		return helloService;
//	}
	
//	public void setFinagleClientRegister(FinagleClientRegister avalue)
//	{
//		this.register = avalue;
//	}
}
